package net.wanho.service.monitor.impl;

import net.wanho.service.monitor.UserOnlineServiceI;
import net.wanho.shiro.dao.ShiroSessionDao;
import org.apache.shiro.session.Session;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.Collection;

@Service
public class UserOnlineServiceImpl implements UserOnlineServiceI {

    @Autowired
    private ShiroSessionDao shiroSessionDao;

    @Override
    public Collection<Session> getActiveSessions() {
        return shiroSessionDao.getActiveSessions();
    }
}
